<template >
    <div>
        <el-table :data="getMember" border style="width: 100%">
            <el-table-column prop="id" label="用户编号" width="180"></el-table-column>
            <el-table-column prop="nickname" label="昵称" width="180"></el-table-column>

            <el-table-column prop="phone" label="手机号"></el-table-column>

            <el-table-column prop="status" label="状态">
                <!-- <el-button size="mini" type="success" plain>启用</el-button> -->
                <template slot-scope="item">
                    <div>
                        {{ item.row.status == 1 ? '开启' : '禁用' }}
                    </div>
                </template>
            </el-table-column>
            <el-table-column label="操作">
                <template slot-scope="item">
                    <div>
                        <el-button size="mini" type="primary" @click="edit(item.row.uid)">编辑</el-button>
                        <!-- <el-button size="mini" type="danger" @click="del(item.row.uid)">删除</el-button> -->
                    </div>
                </template>
            </el-table-column>
        </el-table>
    </div>
</template>
<script>
import { mapActions, mapGetters } from 'vuex'
export default {
    data() {
        return {
        }
    },

    computed: {
        ...mapGetters({
            getMember: 'member/getMember'
        })
    },

    mounted() {
        this.getMemberAction()
    },

    methods: {
        // 调取接口 数据
        ...mapActions({
            getMemberAction: 'member/getMemberAction'
        }),

        edit(uid) {
            this.$emit('edit', uid)
        }

    },

}
</script>
<style lang="">
    
</style>